package com.hectopascal.auth.component;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Component
@Data
@ConfigurationProperties(prefix = "jwt", ignoreInvalidFields = true)
public class JwtConfig {
    //JWT存储的请求头
    private String tokenHeader = "Authorization";
    //JWT加解密使用的密匙
    private String secret = "any-2025-secret-0mka4ODrFldTFXwG8k/+5376XTludziStz7ltoqjxDQ=====";
    //JWT的超期限时间(60*60*24*7)
    private Long expiration = 604800L;
    //JWT负载中拿到的开头
    private String tokenHead = "Bearer ";
    //重复请求时限限制 单位:S
    private Long repeatedRequest = 2L;
}
